<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE html>
<head>
    <meta charset="utf-8">
    <title>java在线网盘系統-后台管理</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
          content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <link rel="stylesheet" href="${ctx}/static/layui/css/layui.css" media="all">
    <script src="${ctx}/static/layui/layui.js"></script>
</head>
<body class="layui-layout-body">
<div class="layui-layout layui-layout-admin">
    <div class="layui-header">
        <div class="layui-logo">java在线网盘系統 管理</div>
        <!-- 头部区域（可配合layui已有的水平导航） -->
        <ul class="layui-nav layui-layout-left">
            <li class="layui-nav-item"><a href="${ctx}/main/class?type=video">视频文件</a></li>
            <li class="layui-nav-item"><a href="#">${user.username}的云网盘</a></li>


        </ul>
        <ul class="layui-nav layui-layout-right">
            <li class="layui-nav-item">云盘剩余空间${user.capacity}MB</li>
<%--            <li class="layui-nav-item">云盘剩余空间</li>--%>
            <li class="layui-nav-item">
                <a href="javascript:;">
                    <img src="http://www.javalm.cn/file/head.png" class="layui-nav-img">
                    ${user.username}
                </a>
                <dl class="layui-nav-child">
                    <dd><a href="${ctx}/updatePassword" target="tqmContent">密码修改</a></dd>
                    <dd><a href="${ctx}/loginOut">退出登录</a></dd>
                </dl>
            </li>
        </ul>
    </div>

    <div class="layui-side layui-bg-black">
        <div class="layui-side-scroll">
            <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
            <ul class="layui-nav layui-nav-tree" lay-filter="test">
                <li class="layui-nav-item layui-nav-itemed">
                    <a class="" href="javascript:;">网盘分类显示</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/main/class?type=movie" target="tqmContent">视频文件</a></dd>
                        <dd><a href="${ctx}/main/class?type=music" target="tqmContent">音乐文件</a></dd>
                        <dd><a href="${ctx}/main/class?type=photo" target="tqmContent">照片文件</a></dd>
                        <dd><a href="${ctx}/main/class?type=document" target="tqmContent">文档文件</a></dd>
                        <dd><a href="${ctx}/main/class?type=zip" target="tqmContent">压缩包文件</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item layui-nav-itemed">
                    <a class="" href="javascript:;">文件管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/main/file?dir=0" target="tqmContent">上传下载</a></dd>
                        <dd><a href="${ctx}/main/file?dir=0" target="tqmContent">文件分享</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item">
                    <a href="javascript:;">资源共享</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/main/public" target="tqmContent">共享资源</a></dd>
                    </dl>
                </li>


                <li class="layui-nav-item">
                    <a href="javascript:;">系统管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/updatePassword" target="tqmContent">信息修改</a></dd>
                    </dl>
                </li>

                <li class="layui-nav-item">
                    <a href="javascript:;">回收站</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/main/remove" target="tqmContent">回收站</a></dd>
                    </dl>
                </li>

                <li class="layui-nav-item">
                    <a href="javascript:;">收藏夹</a>
                    <dl class="layui-nav-child">
                        <dd><a href="${ctx}/main/class?type=move" target="tqmContent">收藏文件</a></dd>
                    </dl>
                </li>

                <c:if test="${user.username=='admin'}">
                    <li class="layui-nav-item">
                        <a href="javascript:;">用户管理</a>
                        <dl class="layui-nav-child">
                            <dd><a href="${ctx}/userList" target="tqmContent">用户列表</a></dd>
                        </dl>
                    </li>
                </c:if>

            </ul>
        </div>
    </div>

    <div class="layui-body">
        <!-- 内容主体区域 -->
        <div style="padding: 0px;height: 100%;width: 100%;">
            <iframe src="demo.jsp" name="tqmContent"
                    style="border: 0px solid blue;height: 100%;width: 100%;scrolling:auto;"></iframe>
        </div>
    </div>

    <div class="layui-footer">
        <!-- 底部固定区域 -->
        © xatu  - 版权区域
    </div>
</div>
<script>
    //JavaScript代码区域
    layui.use('element', function () {
        var element = layui.element;

    });
</script>
</body>
</html>
